Skip to content

Conversation

@knopers8
Copy link
Collaborator

Due to the order of processing in WorstOfAllAggregator, we could get cases when a bad Flag (coming from Bad quality) would be assigned to Good quality, while the quality itself would be replaced just after. This commit reverses the order, which will silence the wrong warning.

@knopers8
Copy link
Collaborator Author

Hello @singiamtel , @ktf , it seems that our builds are all broken: o2 and o2-dataflow-slc9 do not report any status, while macOS-arm fails:

Finished building on aido2osx8.cern.ch at 2025-07-22-08:57:23
Built commit aa8b935132f00e71ab58c504f95cac84c1d654ff from https://github.com/AliceO2Group/QualityControl/pull/2583
Nomad allocation:
    https://alinomad.cern.ch/ui/allocations/f984d447-2a9b-0a5f-eaef-c092e56fb1b2
To log into the build machine, use:
    nomad alloc exec f984d447 bash
To stream logs from the CI process, use:
    nomad alloc logs -stderr -tail -f f984d447
No logs found. Please check the aurora log.
See http://alisw.github.io/infrastructure-pr-testing for more instructions.

could you please have a look?

@singiamtel
Copy link
Collaborator

Hi @knopers8, we're investigating

@knopers8
Copy link
Collaborator Author

Thanks!

Due to the order of processing in WorstOfAllAggregator, we could get cases when a bad Flag (coming from Bad quality) would be assigned to Good quality, while the quality itself would be replaced just after.
This commit reverses the order, which will silence the wrong warning.

The same code was also reused TrendCheck, thus I am fixing it also there.
@knopers8 knopers8 force-pushed the fix-bad-flag-warning branch from aa8b935 to 1d85d6b Compare July 22, 2025 10:51
@singiamtel
Copy link
Collaborator

@knopers8 the issue should be fixed now. Thanks for the report

}
for (const auto& flag : quality.getFlags()) {
result.addFlag(flag.first, flag.second);
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am sorry but it isn't obvious for me how just reversing order of these two operations in one loop would fix the issue. you are creating Quality object, setting it's quality to the one you find as worse (finding the worst) ... aka setting it's level and name... and than adding all flags from all of the qualities encountered in check. So unless I am missing something I don't understand how you achieve with different situation than before.

Copy link
Collaborator

@justonedev1 justonedev1 Jul 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nevermind, I understand, there are internal checks in addFlag ... but just reading the PR isn't obvious why this should fix anything. I would expect that addFlag is just adding flag without any internal checks.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's quite normal that functions validate their inputs, but indeed I could have mentioned where the warning was coming from.

@knopers8 knopers8 merged commit bde6e1b into AliceO2Group:master Jul 31, 2025
6 checks passed
@knopers8 knopers8 deleted the fix-bad-flag-warning branch July 31, 2025 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants